//
//  LeftTableViewCell.m
//  SmileWeather
//
//  Created by lanou3g on 15/9/16.
//  Copyright (c) 2015年 陶天海. All rights reserved.
//

#import "JokeTableCell.h"

@implementation JokeTableCell


- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.selectionStyle = 0;
        self.backgroundColor = [UIColor clearColor];
        self.showLabelOne = [[MyScollview alloc] initWithFrame:CGRectMake(kWidth/11.5,1, kWidth/1.5, 30) str:@"ggggggggggggggggggggggggggg"];
//
        
        self.showLabelOne.userInteractionEnabled = NO;
//        //歌单名
//        self.songListName = [[MyScollview alloc] initWithFrame:CGRectMake(25+self.songsPic.bounds.size.width, 15, kWidth -self.songsPic.bounds.size.width- 35, 35) str:@"ggggggggggggggggggggggggggggg"];
//        self.songListName.userInteractionEnabled = NO;
//        [self.contentView addSubview:self.songListName];
        //self.showLabelOne.backgroundColor = [UIColor blueColor];
        self.showLabelOne.title.font = [UIFont boldSystemFontOfSize:20];
        self.showLabelOne.title.textColor = [UIColor blackColor];
        [self.contentView addSubview:_showLabelOne];
        //
        //        self.ImageV = [[UIImageView alloc] initWithFrame:CGRectMake(kWidth/5,kWidth/5, kWidth/4, 30)];
        //
        //        self.ImageV.backgroundColor = [UIColor redColor];
        //        [self.contentView addSubview:self.ImageV];
        
        self.showLabelTwo = [UIButton  buttonWithType:(UIButtonTypeSystem)];
        self.showLabelTwo.frame = CGRectMake(kWidth * (7/8.0), 1, kWidth/13, 30);
        
        [self.showLabelTwo setBackgroundImage: [UIImage imageNamed:@"loveago.png"] forState:(UIControlStateNormal)];
        //[self.showLabelTwo setTintColor:[UIColor whiteColor]];
        [self.showLabelTwo setBackgroundImage: [UIImage imageNamed:@"love.png"] forState:(UIControlStateSelected)];
        
    
        self.showLabelTwo.selected = NO;
        self.showLabelTwo.layer.masksToBounds = YES;
        self.showLabelTwo.layer.cornerRadius = 20;
        [self.contentView addSubview:self.showLabelTwo];
        
        //笑话简介
        self.JokesIntroduce = [[UILabel alloc] initWithFrame:CGRectMake(kWidth/40, 30, kWidth- kWidth/20, 150)];
       // self.JokesIntroduce.backgroundColor = [UIColor redColor];
        self.JokesIntroduce.textAlignment = 1;
        
        UIView *line = [[UIView alloc] initWithFrame:CGRectMake(kWidth/11.5, 30, kWidth * (3.3/4.0), 1)];
        
        line.backgroundColor = [UIColor whiteColor];
        [self addSubview:line];
        
        //self.accessoryType = 1;
        
         [self setUpSongsIntroduce:self.JokesIntroduce];
        //self.backgroundColor = [UIColor orangeColor];
    }
    return self;
}


- (void)setUpSongsIntroduce:(UILabel *)songIntroduce {
    
    
    songIntroduce.text = @"2015-09-01 11:43:17.314 TthMusic[1125:42736] <UIVisualEffectView 0x7f86d1d74a40> is being asked to animate its opacity. This will cause the effect to appear broken until opacity returns to 1";
    
    
    //换行
    songIntroduce.numberOfLines = 0;
    //文本颜色
    songIntroduce.textColor = [UIColor blackColor];
    //设置字体
    songIntroduce.font = [UIFont boldSystemFontOfSize:16.0];
    [self.contentView addSubview:songIntroduce];
}

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    
   
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
